package com.jblv.frame.web.facade;

import com.jblv.frame.common.dto.PageResult;
import com.jblv.frame.common.dto.UserTokenDTO;
import com.jblv.frame.user.api.dto.SysUserDTO;
import com.jblv.frame.user.api.dto.UserLoginResultDTO;
import com.jblv.frame.user.api.entity.SysUser;
import com.jblv.frame.user.api.params.SysUserListParams;
import com.jblv.frame.user.api.params.UserLoginParams;

/**
 * @author happyonion.yangtao
 * @version 1.0
 * @title ISysUserFacade
 * @projectName jblv-frame
 * @packageName com.jblv.web.facade
 * @description 用户信息门面接口
 * @date Create at 2020/4/28 21:17
 * @since jdk1.8
 */
public interface ISysUserFacade {

    /**
     * 获取当前用户信息
     * @return
     */
    public UserLoginResultDTO get();

    /**
     * 获取单个用户信息
     * @param id
     * @return
     */
    public SysUser get(String id);

    /**
     * 获取用户列表
     * @param params
     * @return
     */
    public PageResult<SysUserDTO> getList(SysUserListParams params);

    public String create(SysUserDTO sysUserDTO);

    public Boolean del(String id);

    public Boolean update(SysUserDTO sysUserDTO);

    public Boolean status(String userId ,Integer status);

    /**
     * 密码登录
     * @param params
     * @return
     */
    public UserTokenDTO pwdLogin(UserLoginParams params);

    /**
     * 管理员登出
     * @return
     */
    public Boolean logout();
}
